export const pointList = [
    {
        name: "选项",
        id: "option",
        val: "option",
    },
    {
        name: "MAP",
        id: "MAP",
        val: "MAP",
    },
]
export const outputTypeOption = [
    { id: 'elasticsearch', name: "elasticsearch" },
    { id: 'email', name: "email" },
    { id: 'file', name: "file" },
    { id: 'google-cloud-storage', name: "google-cloud-storage" },
    { id: 'googlepubsub', name: "googlepubsub" },
    { id: 'grpc', name: "grpc" },
    { id: 'grpc-call', name: "grpc-call" },
    { id: 'grpc-service-response', name: "grpc-service-response" },
    { id: 'hl7', name: "hl7" },
    { id: 'http', name: "http" },
    { id: 'http-call', name: "http-call" },
    { id: 'http-request', name: "http-request" },
    { id: 'http-response', name: "http-response" },
    { id: 'http-service-response', name: "http-service-response" },
    { id: 'inMemory', name: "inMemory" },
    { id: 'jms', name: "jms" },
    { id: 'kafka', name: "kafka" },
    { id: 'kafkaMultiDC', name: "kafkaMultiDC" },
    { id: 'log', name: "log" },
    { id: 'mqtt', name: "mqtt" },
    { id: 'nats', name: "nats" },
    { id: 'prometheus', name: "prometheus" },
    { id: 'rabbitmq', name: "rabbitmq" },
    { id: 's3', name: "s3" },
    { id: 'snmp', name: "snmp" },
    { id: 'sqs', name: "sqs" },
    { id: 'tcp', name: "tcp" },
    { id: 'websocket', name: "websocket" },
    { id: 'websocket-server', name: "websocket-server" }
]

export const mapTypeOption = [
    { id: 1, name: 'avro' },
    { id: 2, name: 'binary' },
    { id: 3, name: 'csv' },
    { id: 4, name: 'json' },
    { id: 5, name: 'keyvalue' },
    { id: 6, name: 'passThrough (default)' },
    { id: 7, name: 'text' },
    { id: 8, name: 'xml' },
]
export const keyValueOption = [
    {
        id: 'ATTRIBUTES',
        name: 'Enter payload as keyvalue pairs',
    },
    {
        id: 'PAYLOAD',
        name: 'Enter a single payload attribute',
    }
]
export const mapList = [
    {
        name: 'avro',
        parameters: [
            {
                defaultValue: '',
                name: 'schema.def',
                optional: false,
                isCheck: true
            },
            {
                defaultValue: '',
                name: 'schema.registry',
                optional: false,
                isCheck: true
            },
            {
                defaultValue: '',
                name: 'schema.id',
                optional: false,
                isCheck: true
            },
            {
                defaultValue: '',
                name: 'fail.on.missing.attribute',
                optional: true,
                isCheck: false
            },
        ]
    },
    {
        name: 'binary',
        parameters: []
    },
    {
        name: 'csv',
        parameters: [
            {
                defaultValue: '',
                name: 'delimiter',
                optional: true,
                isCheck: false
            },
            {
                defaultValue: '',
                name: 'header.present',
                optional: true,
                isCheck: false
            },
            {
                defaultValue: '',
                name: 'fail.on.unknown.attribute',
                optional: true,
                isCheck: false
            },
            {
                defaultValue: '',
                name: 'event.grouping.enabled',
                optional: true,
                isCheck: false
            },
        ]
    },
    {
        name: 'json',
        parameters: [
            {
                defaultValue: '',
                name: 'enclosing.element',
                optional: true,
                isCheck: false
            },
            {
                defaultValue: '',
                name: 'fail.on.missing.attribute',
                optional: true,
                isCheck: false
            },
        ]
    },
    {
        name: 'keyvalue',
        parameters: [
            {
                defaultValue: '',
                name: 'fail.on.missing.attribute',
                optional: true,
                isCheck: false
            },
        ]
    },
    {
        name: 'passThrough (default)',
        parameters: [

        ]
    },
    {
        name: 'text',
        parameters: [
            {
                defaultValue: '',
                name: 'regex.groupid',
                optional: false,
                isCheck: true
            },
            {
                defaultValue: '',
                name: 'fail.on.missing.attribute',
                optional: true,
                isCheck: false
            },
            {
                defaultValue: '',
                name: 'event.grouping.enabled',
                optional: true,
                isCheck: false
            },
            {
                defaultValue: '',
                name: 'delimiter',
                optional: true,
                isCheck: false
            },
            {
                defaultValue: '',
                name: 'new.line.character',
                optional: true,
                isCheck: false
            },
        ]
    },
    {
        name: 'xml',
        parameters: [
            {
                defaultValue: '',
                name: 'namespaces',
                optional: true,
                isCheck: false
            },
            {
                defaultValue: '',
                name: 'enclosing.element',
                optional: true,
                isCheck: false
            },
            {
                defaultValue: '',
                name: 'enclosing.element.as.event',
                optional: true,
                isCheck: false
            },
            {
                defaultValue: '',
                name: 'fail.on.missing.attribute',
                optional: true,
                isCheck: false
            },
        ]
    },
]
export const rdbmsType = [
    {
        name: "内联配置",
        id: 0,
        parameters: [
            {
                name: "jdbc.url",
                optional: false,
                isCheck: true,
                description: "The JDBC URL via which the RDBMS data store is accessed.",
                defaultValue: "",
                zhName: "jdbc地址",
                type: ["STRING"]
            },
            {
                name: "username",
                optional: false, isCheck: true,
                description: "The username to be used to access the RDBMS data store.",
                defaultValue: "",
                zhName: "用户名",
                type: ["STRING"]
            },
            {
                name: "password",
                optional: false, isCheck: true,
                description: "The password to be used to access the RDBMS data store.",
                defaultValue: "",
                zhName: "密码",
                type: ["STRING"]
            },
            {
                name: "jdbc.driver.name",
                optional: false, isCheck: true,
                description: "The driver class name for connecting the RDBMS data store.",
                defaultValue: "",
                zhName: "jdbc驱动程序的名称",
                type: ["STRING"]
            },
            {
                name: "pool.properties",
                optional: true, isCheck: false,
                description: "Any pool parameters for the database connection must be specified as " +
                    "key-value pairs.",
                defaultValue: "null",
                zhName: "数据池属性",
                type: ["STRING"]

            },
            {
                name: "table.name",
                optional: true, isCheck: false,
                description: "The name with which the event table should be persisted in the store." +
                    " If no name is specified via this parameter, the event table is persisted with " +
                    "the same name as the Siddhi table.",
                defaultValue: "The table name defined in the Siddhi App query.",
                zhName: "表名"
            },
            {
                name: "field.length",
                optional: true, isCheck: false,
                description: "The number of characters that the values for fields of the 'STRING' type in" +
                    " the table definition must contain. Each required field must be provided as a " +
                    "comma-separated list of key-value pairs in the [field.name:length] format." +
                    "If this is not specified, the default number of characters specific to the database type is considered.",
                defaultValue: "The table name defined in the Siddhi App query.",
                zhName: "字段长度"
            }

        ]

    },
    {
        name: "数据源",
        id: 1,
        parameters: [
            {
                name: "datasource",
                optional: false, isCheck: true,
                description: "The name of the Carbon datasource that should be used for creating the " +
                    "connection with the database. If this is found, neither the pool properties nor the " +
                    "JNDI resource name described above are taken into account and the connection is " +
                    "attempted via Carbon datasources instead. ",
                defaultValue: "",
                zhName: "数据源",
                type: ["STRING"]
            },
            {
                name: "pool.properties",
                optional: true, isCheck: false,
                description: "Any pool parameters for the database connection must be specified as " +
                    "key-value pairs.",
                defaultValue: "null",
                zhName: "数据池属性",
                type: ["STRING"]
            },
            {
                name: "table.name",
                optional: true, isCheck: false,
                description: "The name with which the event table should be persisted in the store." +
                    " If no name is specified via this parameter, the event table is persisted with " +
                    "the same name as the Siddhi table.",
                defaultValue: "The table name defined in the Siddhi App query.",
                zhName: "表名",
                type: ["STRING"]
            },
            {
                name: "field.length",
                optional: true, isCheck: false,
                description: "The number of characters that the values for fields of the 'STRING' type in" +
                    " the table definition must contain. Each required field must be provided as a " +
                    "comma-separated list of key-value pairs in the [field.name:length] format." +
                    "If this is not specified, the default number of characters specific to the database type is considered.",
                defaultValue: "The table name defined in the Siddhi App query.",
                zhName: "字段长度",
                type: ["STRING"]
            }
        ]
    },
    {
        name: "Jndi资源",
        id: 2,
        parameters: [
            {
                name: "jndi.resource",
                optional: false,
                isCheck: true,
                description: "The name of the JNDI resource through which the connection is attempted. " +
                    "If this is found, the pool properties described above are not taken into account and " +
                    "the connection is attempted via JNDI lookup instead.",
                defaultValue: "",
                zhName: "jndi资源",
                type: ["STRING"]
            },
            {
                name: "pool.properties",
                optional: true, isCheck: false,
                description: "Any pool parameters for the database connection must be specified as " +
                    "key-value pairs.",
                defaultValue: "null",
                zhName: "数据池属性",
                type: ["STRING"]
            },
            {
                name: "table.name",
                optional: true, isCheck: false,
                description: "The name with which the event table should be persisted in the store." +
                    " If no name is specified via this parameter, the event table is persisted with " +
                    "the same name as the Siddhi table.",
                defaultValue: "The table name defined in the Siddhi App query.",
                zhName: "表名",
                type: ["STRING"]
            },
            {
                name: "field.length",
                optional: true, isCheck: false,
                description: "The number of characters that the values for fields of the 'STRING' type in" +
                    " the table definition must contain. Each required field must be provided as a " +
                    "comma-separated list of key-value pairs in the [field.name:length] format." +
                    "If this is not specified, the default number of characters specific to the database type is considered.",
                defaultValue: "The table name defined in the Siddhi App query.",
                zhName: "字段长度",
                type: ["STRING"]
            }
        ]

    }
]